<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        var date = new Date();
date.setFullYear(2022);
date.setMonth(7 - 1);
date.setDate(1);
var year=date.getFullYear();
var month=date.getMonth();
var day=date.getDate();
console.log(year +'年'+(month+1)+'月'+day+'日');
    </script>
</body>
</html>